<link rel="stylesheet" href="libs/codemirror/lib/codemirror.css"> 
<script src="libs/codemirror/lib/codemirror.js"></script> 
<link rel="stylesheet" href="libs/codemirror/mode/xml/xml.css"> 
<script src="libs/codemirror/mode/xml/xml.js"></script> 
<style type="text/css">
.CodeMirror {
  border:1px solid #ddd; height:auto; background:white;
}
</style> 

<!--HTML--------------------------------------------------------------------->
<div class="div_page">
<div class="div_page_inner">

<div class="div_title"> <?php
  echo phrase::__("Configurations"); ?>
</div>
<div>&nbsp;</div>


<div class="div_underlined"><b><?php 
  echo phrase::__("Available modules"); ?></b>
</div> <?php
$last_key = lastkey($this->module_list);
foreach ($this->module_list as $key=>$name) { ?>
  <a target="_blank" href="<?php echo $name; ?>"><?php 
    echo $name; ?></a><?php
  if ($key!=$last_key)
    echo ", ";
}
?>
<div>&nbsp;</div>

<div class="div_underlined"><b><?php 
  echo phrase::__("Protected modules"); ?></b>
</div> <?php
$last_key = lastkey($this->protected_modules);
foreach ($this->protected_modules as $key=>$name) { ?>
  <a target="_blank" href="<?php echo $name; ?>"><?php 
    echo $name; ?></a><?php
  if ($key!=$last_key)
    echo ", ";
}
if (count($this->protected_modules)==0)
  echo phrase::__("No protected modules found");
?>
<div>&nbsp;</div>

<div class="div_underlined">
<b>config.xml</b><br>
The box below is just for viewing, won't take effect if edited
</div> 
<textarea id="txt_xml"><?php
  echo $this->config_xml; ?>
</textarea>

</div>
</div>

<!--CODEMIRROR--------------------------------------------------------------->
<script> 
var editor = CodeMirror.fromTextArea(document.getElementById("txt_xml"), {
  mode:{name:"xml", htmlMode:true},
  lineNumbers:true,
  indentWithTabs:false,
  indentUnit:2,
  readOnly:true
});
</script> 